package com.couldsail.takeaway.pojo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.*;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("products")
public class Products {
    @TableId(value = "id")
    private String id;
    @TableField("name")
    private String name;
    private String description;
    private Integer sort;
    private Double price;
    private Integer stock;// 库存
    @TableField("category_id")
    private String categoryId;
    @TableField("image_url")
    private String imageUrl;
    private Integer status;
    @TableField("created_at")
    private DateTimeFormat createdAt;
    @TableField("updated_at")
    private DateTimeFormat updatedAt;
}
